package com.gxa.dto;

/**
 * Created with IntelliJ IDEA.
 * User: tyg
 * Date: 2020/07/17 16:04
 * Version: V1.0
 * Description:
 */
public class ResultData <T> {

    private int code; //响应状态
    private String msg; //返回信息
    private T data; //返回数据对象

    public ResultData() {
    }

    public ResultData(int code, String msg, T data) {
        this.code = code;
        this.msg = msg;
        this.data = data;
    }

    public ResultData(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }

    @Override
    public String toString() {
        return "ResultData{" +
                "code=" + code +
                ", msg='" + msg + '\'' +
                ", data=" + data +
                '}';
    }
}
